home *** CD-ROM | disk | FTP | other *** search
/ The X-Philes (2nd Revision) / The X-Philes Number 1 (1995).iso / xphiles / hp48hor2 / timeeval.doc < prev    next >
Text File  |  1995-03-31  |  2KB  |  47 lines

  1. TIMEEVAL, an object-execution timer v1.0 
  2. From: phk@data.fls.dk (Poul-Henning Kamp) 
  3. Newsgroups: comp.sources.hp48 
  4. Date: 1 Oct 91 02:38:36 GMT 
  5.  
  6. [Note: This is for those who desire the functionality of the XTIME command in 
  7.  Jim Donnelly's TOOL LIBRARY (a commercial product) without having that whole 
  8.  library in memory.  -jkh-] 
  9.  
  10. obj  TIMEEVAL  -->  n(ticks) x_ms 
  11.  
  12. Evaluates the object on top of the stack, and returns the time it took in 
  13. ticks of the internal clock and in milli-seconds. 
  14.  
  15. Arguments for <obj> can put put on the stack above it, and results from the 
  16. evaluation will be available above the results of TIMEEVAL. 
  17.  
  18. example: 
  19.          +----------------------+                  +----------------------+ 
  20.          |4:                    |                  |4:                    | 
  21.          |3:                    |                  |3:       .908508177527| 
  22.          |2:                65.3|                  |2:                 247| 
  23.          |1:                 SIN|  -> TIMEEVAL ->  |1:           30.151_ms| 
  24.          +----------------------+                  +----------------------+ 
  25.  
  26.  
  27. You cannot get SIN onto the stack ?  try this: { SIN } OBJ\-> DROP 
  28.  
  29. The T0 offset is (on my calc, Rev E) 31 ticks, or 3.784_ms.  This is roughly 
  30. the time it takes to evaluate a data-object like "Hello". 
  31.  
  32. WARNINGS: 
  33. ========= 
  34.  
  35. The EVAL employed is the "kernel-one", which does not evalute inside lists. 
  36.  
  37. Programs relying on a specific local-env will fail if they use 1GETLAM &c &c. 
  38.  
  39. There is no ERRTRAP built in. 
  40.  
  41. --  
  42. phk@data.fls.dk           ||  A host is a host from coast to coast, 
  43. Poul-Henning Kamp         ||  & no one will talk to a host that's close, 
  44. FLS DATA A/S              ||  Unless the host (that isn't close) 
  45. Phone: (+45) 36 18 12 35  ||  is busy, hung or dead. 
  46. Fax:   (+45) 36 18 12 18  ||                 Anon (?)  
  47.